
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.ComponentModel.Composition;
using System.Threading.Tasks;
using Red.Controls.Shell;
using Red.Controls.ViewModels;

namespace BeefSandbox
{
    [Export( typeof( IEditorInfo ) )]
    public class EditorInfo : IEditorInfo
    {
        public string Name
        {
            get { return "Beef's sandbox"; }
        }

        public Type WindowClass
        {
            get { return typeof( BeefSandbox ); }
        }

        public Type SettingsClass
        {
            get { return typeof( UserSettings ); }
        }
    }

    /// <summary>
    /// Interaction logic for MainWindow.xaml
    /// </summary>
    public partial class BeefSandbox : RedEditorWindow
    {
        public BeefSandbox( IEditorHost host, EditorInstanceData instanceData, EditorSharedData sharedData )
            : base( host, instanceData, sharedData )
        {
            InitializeComponent();
            var root = new TestDataItem_Root();
            root.IsExpanded = true;
            _dataCategory.DataContext = root;
        }

        private void Button_Click( object sender, System.Windows.RoutedEventArgs e )
        {
            if ( _leftDrawer.ActivePage == _pageLeft1 )
                _leftDrawer.ActivePage = _pageLeft2;
            else
                _leftDrawer.ActivePage = _pageLeft1;
        }

    }
}
